Software Development
Java Persistence API with Hibernate
Java Persistence API: Configuring Fields & Performing CRUD Operations
Java Persistence API: Embedding Collections & Managing Cascade Operations
Java Persistence API: Executing Queries & Managing the Entity Lifecycle
Java Persistence API: Getting Started With JPA & Hibernate
Java Persistence API: Mapping & Configuring Relationships

Java Persistence API: Configuring Fields & Performing CRUD Operations

Course Number:
it_jmjpehdj_02_enus
Lesson Objectives

Java Persistence API: Configuring Fields & Performing CRUD Operations

  • discover the key concepts covered in this course
  • recognize the primary key as a required field
  • configure the table name using the @Table annotation
  • use @GeneratedValue to generate primary key values
  • contrast the AUTO and IDENTITY genaration types
  • use the IDENTITY generation type for multiple tables
  • use the SEQUENCE generation type
  • use the TABLE generation type
  • configure composite keys using @Embeddable and @Id annotations
  • configure composite keys using @EmbeddedId annotation
  • configure composite keys using the @IdClass annotation
  • apply the @Column annotation to define columns
  • specify precision and scale values for floating point columns
  • specify not null and uniqueness constraints
  • annotate non-persistable fields using @Transient
  • use the @Temporal annotation for date fields
  • use the @Lob annotation for large objects
  • configure embeddable entities as persistent fields
  • share embeddable objects across entities
  • use begin and commit transactions
  • perform read operations on database entities
  • perform update and delete operations on entities
  • specify entity attributes using XML
  • summarize the key concepts covered in this course

Overview/Description

In this course, you'll explore how primary keys can be set up for the tables underlying your entities and how you can manage the configuration of individual columns in your database columns using JPA annotations. You'll learn how to perform create, read, update, and delete operations using the JPA entity manager.

Once you're done with this course, you'll be able to structure your entities and their attributes based exactly on your specifications and perform basic storage and retrieval operations using JPA and Hibernate.



Target

Prerequisites: none

Java Persistence API: Embedding Collections & Managing Cascade Operations

Course Number:
it_jmjpehdj_04_enus
Lesson Objectives

Java Persistence API: Embedding Collections & Managing Cascade Operations

  • discover the key concepts covered in this course
  • define collection mapping for primitive data types
  • configure lazy and eager loading for collections
  • persist collections using the Set interface
  • persist nested objects in collections
  • persist collections defined using the Map interface
  • configure maps using @MapKeyColumn and @MapColumn
  • use embeddable objects as map values
  • use entities as map values
  • use entities as map keys
  • recall the implications of cascade type NONE
  • summarize the effects of cascade type PERSIST and REMOVE
  • summarize the effects of cascade type MERGE
  • summarize the effects of cascade type DETACH and ALL
  • apply the @MappedSuperclass annotation to parent classes
  • recall the effects of persisting derived entities with a mapped superclass
  • use the SINGLE_TABLE inheritance to store all entities in a single table
  • specify discriminator columns with specific discriminator values
  • configure entities to handle null and unknown discriminator values
  • use the TABLE_PER_CLASS inheritance to store entities in multiple tables
  • use the JOINED inheritance to store entities in multiple tables
  • summarize the key concepts covered in this course

Overview/Description

In this course, you'll explore how nested collections within an outer entity can be mapped using JPA. You'll implement mappings for collections of primitive types, embeddable objects, and collections of entities. You'll examine how JPA and Hibernate handle list, set, and map collections.

Next, you'll relate how specific operations such as entity persistence, update, and removal can be cascaded from parent entities to child entities and illustrate how inheritance relationships in your code can be mapped to database tables.

Once you're done with this course, you'll be able to use nested collections within your entities and also map inheritance relationships in your code to meaningful representations using tables.



Target

Prerequisites: none

Java Persistence API: Executing Queries & Managing the Entity Lifecycle

Course Number:
it_jmjpehdj_05_enus
Lesson Objectives

Java Persistence API: Executing Queries & Managing the Entity Lifecycle

  • discover the key concepts covered in this course
  • execute native queries
  • execute JPQL queries
  • configure dynamic JPQL queries using named and positional parameters
  • reference foreign keys within JPQL queries
  • perform join operations using JPQL queries
  • retrieve multiple fields using JPQL queries
  • construct special objects to hold multiple fields within JPQL queries
  • execute update and delete JPQL queries
  • define and use named queries
  • summarize the basic structure of the Criteria API
  • run basic criteria queries
  • run advanced criteria queries
  • hook into the entity lifecycle before and after entity persistence
  • hook into the entity lifecycle after load
  • hook into the entity lifecycle before and after entity load
  • hook into the entity lifecycle before and after entity removal
  • configure an entity listener object for callbacks
  • summarize the key concepts covered in this course

Overview/Description

In this course, you'll explore a variety of ways to execute queries using JPA. You'll run native queries, queries using JPQL, and queries using the Criteria API, which helps avoid syntax errors in your query specification.

Next, you'll examine how you can have entity-specific callback methods that can be invoked at different stages in the entity's lifecycle. When you are done with this course, you'll be able to perform complex queries on your database tables and manage your entity's lifecycle in a very granular manner.



Target

Prerequisites: none

Java Persistence API: Getting Started With JPA & Hibernate

Course Number:
it_jmjpehdj_01_enus
Lesson Objectives

Java Persistence API: Getting Started With JPA & Hibernate

  • discover the key concepts covered in this course
  • identify why object-relational mapping is needed to work with databases
  • outline the basic functionality that the Hibernate framework provides and how it differs to JPA
  • outline the basic functionality that the JPA framework provides and how it differs to Hibernate
  • install MySQL and MySQL Workbench on a Windows machine
  • set up an Apache Maven project on a Windows machine
  • install MySQL and MySQL Workbench on a macOS machine
  • set up an Apache Maven project on a macOS machine
  • configure JPA and Hibernate dependencies in pom.xml
  • represent entities and primary keys using annotations
  • configure database connection details in persistence.xml
  • store entities in the underlying database using the entity manager
  • configure the range of actions that can be performed using persistence.xml
  • configure drop and create actions using scripts
  • summarize the key concepts covered in this course

Overview/Description

JPA, or the Java Persistence API, is focused on persistence. Persistence can refer to any mechanism by which Java objects outlive the applications that created them. JPA is not a tool, or a framework, or an actual implementation.

In this course, you'll explore the basic ideas behind object-relational mapping, where entities and relationships expressed in an object-oriented framework are mapped to records and tables in a relational database.

You'll examine the basic features of the JPA and Hibernate frameworks. You'll then practice how to get set up with the MySQL database, the MySQL Workbench, and Apache Maven to manage dependencies in your Java application.



Target

Prerequisites: none

Java Persistence API: Mapping & Configuring Relationships

Course Number:
it_jmjpehdj_03_enus
Lesson Objectives

Java Persistence API: Mapping & Configuring Relationships

  • discover the key concepts covered in this course
  • set up a one-to-one mapping between entities
  • configure join columns for one-to-one mapping
  • set up a bidirectional one-to-one mapping between entities
  • configure one-to-one-mapping with a shared primary key
  • configure one-to-one mapping with a join table
  • set up a one-to-many unidirectional mapping
  • configure a one-to-many mapping with a join table
  • configure eager loading of entities on the many side
  • configure lazy loading of entities on the many side
  • configure one-to-many mapping with join columns
  • retrieve many entities in order of specific attributes
  • persist entities in a certain order
  • set up a many-to-one unidirectional mapping
  • configure a many-to-one mapping with multiple join columns
  • configure a many-to-one mapping with a join table
  • set up a one-to-many, many-to-one bidirectional mapping
  • retrieve entities mapped in both directions
  • configure the owning side and owned side in mappings
  • set up a many-to-many bidirectional mapping
  • summarize the key concepts covered in this course

Overview/Description

In this course, you'll explore the various kinds of relationships that you might want to express using JPA annotations and how these relationships map to relational table design. You'll examine unidirectional as well as bidirectional one-to-one, one-to-many, many-to-one, and many-to-many relationships.

Once you're done with this course, you'll be able to model and express real-world relationships between your entities using JPA annotations. Finally, you'll learn how to finely manipulate how you want these relationships configured using underlying database tables.



Target

Prerequisites: none

Close Chat Live